#pragma once

#include "vrdatacore_global.h"
#include "drawableactor.h"
#include "commonshape.h"

namespace VrDataCore
{
	class VRDATACORE_EXPORT ObscuredPlaneActor:public DrawableActor
	{
	public:
		ObscuredPlaneActor(void);

		void setVertexList(QString vertex);
		QString getVertexList();
		void setPlaneImage(QString image);
		QString getPlaneImage();
		void setVertexVector(std::vector<osg::Vec3> vector);
		std::vector<osg::Vec3> getVertexVector();
		void showPlaneLine(bool show);
		void updateLine(std::vector<osg::Vec3> pointvector);
	protected:
		virtual ~ObscuredPlaneActor(void);
		virtual void createDrawable();
		virtual void initialNode();
		void getVertex();
		void getStateSet();
		void initStateValue();
		osg::ref_ptr<CoreBase::PlaneShape>					_plane;
		QString												_vertexList;
		QString												_image;
		std::vector<osg::Vec3>								_vertexVector;
		osg::ref_ptr<osg::StateSet>							_ss;
	public:
		virtual void buildPropertyMap();
		virtual void onMapLoadEnd(CoreBase::Map* map);
		virtual osg::ref_ptr<CoreBase::ActorBase> clone();
	};
}